package datasource.review;

import java.util.ArrayList;
import java.util.Date;
import java.util.HashMap;
import java.util.Random;

import thesis.DataObject;

public class ReviewObject extends DataObject {
	private final int numTime = 20;
	private double[] topicProb = { 0.7, 0.6, 0.3, 0.5, 0.2, 0.4 };
	private double[] sentiProb = { 0.4, 0.5, 1 };

	public ReviewObject(long id) {
		super(id);
		timeCluster = new Random().nextInt(numTime);
		rating = new Random().nextInt(5);
		for (int i = 0; i < topicProb.length; i++) {
			if (topicProb[i] > new Random().nextDouble()) {
				double senti = new Random().nextDouble();
				int count = 0;
				while (senti > sentiProb[count]) {
					count++;
				}
				topic.put(i + "_" + count, new Random().nextDouble());
			}
		}

	}

	ArrayList<String> sentences = new ArrayList<String>();
	Date time = null;
	int rating;
	int timeCluster;
	HashMap<String, Double> topic = new HashMap();

}
